<script type="text/javascript">
function checkform()
{
	var names = document.getElementsByName("itemname");
	//alert(names.length);
	if(names.length==0)
	{
		alert("当前无质量控制点！");
		return;
	}
	for(var i=0;i<names.length;i++)
	{
		//alert(names[i].value);
		if(names[i].value=="")
		{
			alert("当前质量控制点名称不能为空！");
			return;
		}
	}
}
</script>
<style type="text/css">
#main table {
	border-top:1px #666666 solid;
	border-right:1px #666666 solid;
	
}
#main table tr:hover td { background: #FFFB82; cursor:pointer; color:#000000;}/*隔行换色鼠标经过效果*/
#main td {
	border-left:1px #666666 solid;
	border-bottom:1px #666666 solid;
	height:29px;
	overflow:hidden;
}
</style>
<form action="/system/editScoreSubItems.do" method="post"  name="fom">
<table width="90%" style="margin-top:20px;" border="0" align="center" cellpadding="10" cellspacing="0">
	<tr>
		<td>
		<div id="main">
			<h3>质量控制点修改</h3>
			<fieldset>
				<table width="100%" border="0" cellpadding="0" cellspacing="0">
				  <tr style="color:#FFFFFF">
					<td width="15%" align="center" valign="middle" bgcolor="#333333"><strong>所属分项</strong></td>
				    <td width="30%" align="center" valign="middle" bgcolor="#333333"><strong>质量控制点名称</strong></td>
				    <td width="35%" align="center" valign="middle" bgcolor="#333333"><strong>合格描述</strong></td>
				    <td width="20%" align="center" valign="middle" bgcolor="#333333"><strong>操作</strong></td>
				  </tr>
				  #foreach($item in $itemList)
				  <tr>
                    <td align="center" valign="middle">
                    $!scoreTree.cateName
                    </td>
				    <td align="center" valign="middle">
				    	<input name="itemname" id="itemname" type="text" value="$!item.itemName" size="30" />
						<input name="id"  type="hidden" value="$!item.id"  />
				    </td>
				    <td align="center" valign="middle">
				    	<textarea name="itemdesc" id="itemdesc" cols="50" rows="4">$!item.itemDesc</textarea>
				    </td>
				    <td align="center" valign="middle">
				    	<a href="/system/editScoreUrlDesc.jsp?id=$item.id">修改评细描述</a>	
				     </td>
			      </tr>
				  #end
				  <tr>
					  <td height="80" align="left" colspan="4">
					  <br>
					  <input name="pid"  type="hidden" value="$pid"  />
					  <input type="submit" style="background:url(../images/button-submit.gif) left top no-repeat; border:none; cursor:pointer; width:94px; height:29px; line-height:29px; vertical-align:middle;" value="保　存" onclick="javascript:return checkform();"/>
			          <input type="button" style="background:url(../images/button-submit.gif) left top no-repeat; border:none; cursor:pointer; width:94px; height:29px; line-height:29px; vertical-align:middle;" value="返　回" onclick="window.history.go(-1);"/>
			          <br>
			          </td>
			         
				  </tr>
				</table>
			</fieldset>
		</div>
		</td>
	</tr>
</table>
</form>